﻿using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace COVID_19_LiquidFillUI.Migrations
{
    public partial class addClass : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.CreateTable(
                name: "MDrawCircles",
                columns: table => new
                {
                    Id = table.Column<int>(type: "INTEGER", nullable: false)
                        .Annotation("Sqlite:Autoincrement", true),
                    Kind = table.Column<int>(type: "INTEGER", nullable: false),
                    Row = table.Column<double>(type: "REAL", nullable: false),
                    Column = table.Column<double>(type: "REAL", nullable: false),
                    Radius = table.Column<double>(type: "REAL", nullable: false),
                    MeasureThrehold = table.Column<int>(type: "INTEGER", nullable: false),
                    ST_Radius = table.Column<double>(type: "REAL", nullable: false),
                    PcsOrder = table.Column<int>(type: "INTEGER", nullable: false)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_MDrawCircles", x => x.Id);
                });

            migrationBuilder.CreateTable(
                name: "MJudges",
                columns: table => new
                {
                    Id = table.Column<int>(type: "INTEGER", nullable: false)
                        .Annotation("Sqlite:Autoincrement", true),
                    Kind = table.Column<int>(type: "INTEGER", nullable: false),
                    PcsOrder = table.Column<int>(type: "INTEGER", nullable: false),
                    CircleIndex0 = table.Column<int>(type: "INTEGER", nullable: false),
                    CircleIndex1 = table.Column<int>(type: "INTEGER", nullable: false),
                    ST_Dist = table.Column<double>(type: "REAL", nullable: false)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_MJudges", x => x.Id);
                });

            migrationBuilder.CreateTable(
                name: "MVisionPoint2s",
                columns: table => new
                {
                    Id = table.Column<int>(type: "INTEGER", nullable: false)
                        .Annotation("Sqlite:Autoincrement", true),
                    Kind = table.Column<int>(type: "INTEGER", nullable: false),
                    PcsOrder = table.Column<int>(type: "INTEGER", nullable: false),
                    ThresholdMin = table.Column<int>(type: "INTEGER", nullable: false),
                    ThresholdMax = table.Column<int>(type: "INTEGER", nullable: false),
                    JudgeArea = table.Column<int>(type: "INTEGER", nullable: false)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_MVisionPoint2s", x => x.Id);
                });
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropTable(
                name: "MDrawCircles");

            migrationBuilder.DropTable(
                name: "MJudges");

            migrationBuilder.DropTable(
                name: "MVisionPoint2s");
        }
    }
}
